package com.javaee.exam.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.javaee.exam.service.CategoryService;
import com.javaee.exam.utils.ServicesResponse;

@RestController
@RequestMapping("/category")
public class CategoryController {
	@Autowired
	private CategoryService categoryBiz;

	@RequestMapping("/list")
	public ServicesResponse list() {

		return ServicesResponse.success(100, "success", categoryBiz.list());
	}
}
